﻿<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8" />
    <title>后台管理系统</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <!-- basic styles -->
    <link href="@Url.Content("~/Content/css/bootstrap.min.css")" rel="stylesheet" />
    <link href="@Url.Content("~/Content/css/font-awesome.min.css")" rel="stylesheet" />
    <!--[if IE 7]>
		  <link rel="stylesheet" href="@Url.Content("~/Content/css/font-awesome-ie7.min.css")" />
		<![endif]-->
    <!-- page specific plugin styles -->
    <link rel="stylesheet" href="@Url.Content("~/Content/css/jquery-ui-1.10.3.full.min.css")" />
    <link rel="stylesheet" href="@Url.Content("~/Content/css/datepicker.css")" />
    <link rel="stylesheet" href="@Url.Content("~/Content/css/ui.jqgrid.css")" />
    <!-- fonts -->
    <link href="@Url.Content("~/Content/font/font.css")" rel="stylesheet" />
    <!-- ace styles -->
    <link rel="stylesheet" href="@Url.Content("~/Content/css/ace.min.css")" />
    <link rel="stylesheet" href="@Url.Content("~/Content/css/ace-rtl.min.css")" />
    <link rel="stylesheet" href="@Url.Content("~/Content/css/ace-skins.min.css")" />
    <!--[if lte IE 8]>
		  <link rel="stylesheet" href="@Url.Content("~/Content/css/ace-ie.min.css")" />
		<![endif]-->
    <!-- inline styles related to this page -->
    <!-- ace settings handler -->
    <script src="@Url.Content("~/Content/js/ace-extra.min.js")"></script>
    <style>
        body
        {
            font-family: '微软雅黑';
            overflow-y: hidden;
        }
        .ui-dialog-titlebar-close
        {
            outline: none;
        }
        .ui-dialog-buttonpane
        {
            margin-top: 0px !important;
        }
        .nav-list > li.active:after
        {
            border: none;
        }
        .nav-list li.active > a:after
        {
            display: none;
        }
    </style>
</head>
<body>
    <div class="navbar navbar-default" id="navbar">
        <script type="text/javascript">
            try { ace.settings.check('navbar', 'fixed') } catch (e) { }
        </script>
        <div class="navbar-container" id="navbar-container">
            <div class="navbar-header pull-left">
                <a href="javascript:void(0)" class="navbar-brand"><small><i class="icon-leaf"></i>&nbsp;后台管理系统
                </small></a>
                <!-- /.brand -->
            </div>
            <!-- /.navbar-header -->
            <div class="navbar-header pull-right" role="navigation">
                <ul class="nav ace-nav">
                    <li class="grey"><a data-toggle="dropdown" class="dropdown-toggle" href="javascript:void(0)">
                        <i class="icon-tasks"></i><span class="badge badge-grey">4</span> </a>
                        <ul class="pull-right dropdown-navbar dropdown-menu dropdown-caret dropdown-close">
                            <li class="dropdown-header"><i class="icon-ok"></i>还有4个任务完成 </li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left">软件更新</span> <span class="pull-right">65%</span>
                                </div>
                                <div class="progress progress-mini ">
                                    <div style="width: 65%" class="progress-bar ">
                                    </div>
                                </div>
                            </a></li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left">硬件更新</span> <span class="pull-right">35%</span>
                                </div>
                                <div class="progress progress-mini ">
                                    <div style="width: 35%" class="progress-bar progress-bar-danger">
                                    </div>
                                </div>
                            </a></li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left">单元测试</span> <span class="pull-right">15%</span>
                                </div>
                                <div class="progress progress-mini ">
                                    <div style="width: 15%" class="progress-bar progress-bar-warning">
                                    </div>
                                </div>
                            </a></li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left">错误修复</span> <span class="pull-right">90%</span>
                                </div>
                                <div class="progress progress-mini progress-striped active">
                                    <div style="width: 90%" class="progress-bar progress-bar-success">
                                    </div>
                                </div>
                            </a></li>
                            <li><a href="#">查看任务详情 <i class="icon-arrow-right"></i></a></li>
                        </ul>
                    </li>
                    <li class="purple"><a data-toggle="dropdown" class="dropdown-toggle" href="#"><i
                        class="icon-bell-alt"></i><span class="badge badge-important">8</span> </a>
                        <ul class="pull-right dropdown-navbar navbar-pink dropdown-menu dropdown-caret dropdown-close">
                            <li class="dropdown-header"><i class="icon-warning-sign"></i>8条通知 </li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left"><i class="btn btn-xs no-hover btn-pink icon-comment"></i>新闻评论
                                    </span><span class="pull-right badge badge-info">+12</span>
                                </div>
                            </a></li>
                            <li><a href="#"><i class="btn btn-xs btn-primary icon-user"></i>切换为编辑登录.. </a></li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left"><i class="btn btn-xs no-hover btn-success icon-shopping-cart">
                                    </i>新订单 </span><span class="pull-right badge badge-success">+8</span>
                                </div>
                            </a></li>
                            <li><a href="#">
                                <div class="clearfix">
                                    <span class="pull-left"><i class="btn btn-xs no-hover btn-info icon-twitter"></i>粉丝
                                    </span><span class="pull-right badge badge-info">+11</span>
                                </div>
                            </a></li>
                            <li><a href="#">查看所有通知 <i class="icon-arrow-right"></i></a></li>
                        </ul>
                    </li>
                    <li class="green"><a data-toggle="dropdown" class="dropdown-toggle" href="#"><i class="icon-envelope">
                    </i><span class="badge badge-success">5</span> </a>
                        <ul class="pull-right dropdown-navbar dropdown-menu dropdown-caret dropdown-close">
                            <li class="dropdown-header"><i class="icon-envelope-alt"></i>5条消息 </li>
                            <li><a href="#">
                                <img src="~/Content/avatars/avatar.png" class="msg-photo" alt="Alex's Avatar" />
                                <span class="msg-body"><span class="msg-title"><span class="blue">Alex:</span> 不知道写啥
                                    ... </span><span class="msg-time"><i class="icon-time"></i><span>1分钟以前</span> </span>
                                </span></a></li>
                            <li><a href="#">
                                <img src="~/Content/avatars/avatar3.png" class="msg-photo" alt="Susan's Avatar" />
                                <span class="msg-body"><span class="msg-title"><span class="blue">Susan:</span> 不知道翻译...
                                </span><span class="msg-time"><i class="icon-time"></i><span>20分钟以前</span> </span>
                                </span></a></li>
                            <li><a href="#">
                                <img src="~/Content/avatars/avatar4.png" class="msg-photo" alt="Bob's Avatar" />
                                <span class="msg-body"><span class="msg-title"><span class="blue">Bob:</span> 到底是不是英文
                                    ... </span><span class="msg-time"><i class="icon-time"></i><span>下午3:15</span> </span>
                                </span></a></li>
                            <li><a href="inbox.html">查看所有消息 <i class="icon-arrow-right"></i></a></li>
                        </ul>
                    </li>
                    <li class="light-blue"><a data-toggle="dropdown" href="#" class="dropdown-toggle">
                        <img class="nav-user-photo" src="~/Content/avatars/avatar4.png" alt="Jason's Photo" />
                        <span class="user-info"><small>欢迎光临,</small> Jason </span><i class="icon-caret-down">
                        </i></a>
                        <ul class="user-menu pull-right dropdown-menu dropdown-yellow dropdown-caret dropdown-close">
                            <li><a href="#"><i class="icon-cog"></i>设置 </a></li>
                            <li><a href="#"><i class="icon-user"></i>个人资料 </a></li>
                            <li class="divider"></li>
                            <li><a href="#"><i class="icon-off"></i>退出 </a></li>
                        </ul>
                    </li>
                </ul>
                <!-- /.ace-nav -->
            </div>
            <!-- /.navbar-header -->
        </div>
        <!-- /.container -->
    </div>
    <div class="main-container" id="main-container">
        <script type="text/javascript">
            try { ace.settings.check('main-container', 'fixed') } catch (e) { }
        </script>
        <div class="main-container-inner">
            <a class="menu-toggler" id="menu-toggler" href="#"><span class="menu-text"></span>
            </a>
            <div>
                <div class="sidebar" id="sidebar">
                    <script type="text/javascript">
                        try { ace.settings.check('sidebar', 'fixed') } catch (e) { }
                    </script>
                    <div class="sidebar-shortcuts" id="sidebar-shortcuts">
                        <div class="sidebar-shortcuts-large" id="sidebar-shortcuts-large">
                            <button class="btn btn-success">
                                <i class="icon-file"></i>
                            </button>
                            <button class="btn btn-info">
                                <i class="icon-pencil"></i>
                            </button>
                            <button class="btn btn-warning">
                                <i class="icon-group"></i>
                            </button>
                            <button class="btn btn-danger">
                                <i class="icon-time"></i>
                            </button>
                        </div>
                        <div class="sidebar-shortcuts-mini" id="sidebar-shortcuts-mini">
                            <span class="btn btn-success"></span><span class="btn btn-info"></span><span class="btn btn-warning">
                            </span><span class="btn btn-danger"></span>
                        </div>
                    </div>
                    <!-- #sidebar-shortcuts -->
                    <ul class="nav nav-list">
                        <li class="active"><a href="#" class="dropdown-toggle"><i class="icon-cogs"></i><span
                            class="menu-text">数据维护 </span><b class="arrow icon-angle-down"></b></a>
                            <ul class="submenu">
                                @foreach (KeyValuePair<string, string> menu in @Model[0])
                                {
                                    <li><a href="javascript:void(0)" target="@menu.Key"><i class="icon-chevron-right"></i>
                                        <span class='menu-text'>@menu.Value</span></a></li>
                                }
                            </ul>
                        </li>
                        <li class="active"><a href="#" class="dropdown-toggle"><i class="icon-signal"></i><span
                            class="menu-text">统计分析 </span><b class="arrow icon-angle-down"></b></a>
                            <ul class="submenu">
                                @foreach (KeyValuePair<string, string> menu in @Model[1])
                                {
                                    <li><a href="javascript:void(0)" target="@menu.Key"><i class="icon-chevron-right"></i>
                                        <span class='menu-text'>@menu.Value</span></a></li>
                                }
                            </ul>
                        </li>
                    </ul>
                    <!-- /.nav-list -->
                    <div class="sidebar-collapse" id="sidebar-collapse">
                        <i class="icon-double-angle-left" data-icon1="icon-double-angle-left" data-icon2="icon-double-angle-right">
                        </i>
                    </div>
                    <script type="text/javascript">
                        try { ace.settings.check('sidebar', 'collapsed') } catch (e) { }
                    </script>
                </div>
            </div>
            <div class="main-content">
                <div class="breadcrumbs" id="breadcrumbs">
                    <script type="text/javascript">
                        try { ace.settings.check('breadcrumbs', 'fixed') } catch (e) { }
                    </script>
                    <ul class="breadcrumb">
                        <li><i class="icon-home home-icon"></i><a href="#">首页</a> </li>
                        <li class="active">数据维护</li>
                        <li class="active">单位管理</li>
                    </ul>
                    <!-- .breadcrumb -->
                    <div class="nav-search" id="nav-search">
                        <form class="form-search">
                        <span class="input-icon">
                            <input type="text" placeholder="Search ..." class="nav-search-input" id="nav-search-input"
                                autocomplete="off" />
                            <i class="icon-search nav-search-icon"></i></span>
                        </form>
                    </div>
                    <!-- #nav-search -->
                </div>
                <iframe id="frameContent" style="width: 100%; border: none;"></iframe>
            </div>
            <!-- /.main-content -->
            <div class="ace-settings-container" id="ace-settings-container">
                <div class="btn btn-app btn-xs btn-warning ace-settings-btn" id="ace-settings-btn">
                    <i class="icon-cog bigger-150"></i>
                </div>
                <div class="ace-settings-box" id="ace-settings-box">
                    <div>
                        <div class="pull-left">
                            <select id="skin-colorpicker" class="hide">
                                <option data-skin="default" value="#438EB9">#438EB9</option>
                                <option data-skin="skin-1" value="#222A2D">#222A2D</option>
                                <option data-skin="skin-2" value="#C6487E">#C6487E</option>
                                <option data-skin="skin-3" value="#D0D0D0">#D0D0D0</option>
                            </select>
                        </div>
                        <span>&nbsp; 选择皮肤</span>
                    </div>
                    <div>
                        <input type="checkbox" class="ace ace-checkbox-2" id="ace-settings-navbar" />
                        <label class="lbl" for="ace-settings-navbar">
                            固定导航条</label>
                    </div>
                    <div>
                        <input type="checkbox" class="ace ace-checkbox-2" id="ace-settings-sidebar" />
                        <label class="lbl" for="ace-settings-sidebar">
                            固定滑动条</label>
                    </div>
                    <div>
                        <input type="checkbox" class="ace ace-checkbox-2" id="ace-settings-breadcrumbs" />
                        <label class="lbl" for="ace-settings-breadcrumbs">
                            固定面包屑</label>
                    </div>
                    <div>
                        <input type="checkbox" class="ace ace-checkbox-2" id="ace-settings-rtl" />
                        <label class="lbl" for="ace-settings-rtl">
                            切换到左边</label>
                    </div>
                    <div>
                        <input type="checkbox" class="ace ace-checkbox-2" id="ace-settings-add-container" />
                        <label class="lbl" for="ace-settings-add-container">
                            切换窄屏 <b></b>
                        </label>
                    </div>
                </div>
            </div>
            <!-- /#ace-settings-container -->
        </div>
        <!-- /.main-container-inner -->
    </div>
    <div id="dialog-editor" class="hide" style="padding: 0; overflow-y: hidden">
        <iframe style="border: none; width: 100%;"></iframe>
    </div>
    <div id="dialog-confirm" class="hide">
        <div class="space-6">
        </div>
        <p class="bigger-110 bolder center grey">
        </p>
    </div>
    <div id="content-Loading" style="display: none; position: fixed; width: 100%; height: 100%;
        background: rgba(255, 255, 255, 0.7); z-index: 999; text-align: center">
        <h4>
            <i class="icon-spinner icon-spin orange bigger-125"></i>&nbsp;正在加载...</h4>
    </div>
    <!-- /.main-container -->
    <!-- basic scripts -->
    <script type="text/javascript">
        window.jQuery || document.write("<script src='Content/js/jquery-2.0.3.min.js'>" + "<" + "script>");
    </script>
    <!--[if IE]>
        <script type="text/javascript">
            window.jQuery || document.write("<script src='Content/js/jquery-1.10.2.min.js'>"+"<"+"script>");
        </script>
    <![endif]-->
    <script type="text/javascript">
        if ("ontouchend" in document) document.write("<script src='Content/js/jquery.mobile.custom.min.js'>" + "</" + "script>");
    </script>
    <script src="@Url.Content("~/Content/js/bootstrap.min.js")"></script>
    <script src="@Url.Content("~/Content/js/typeahead-bs2.min.js")"></script>
    <!--[if lte IE 8]>
		  <script src="assets/js/excanvas.min.js"></script>
		<![endif]-->
    <script src="@Url.Content("~/Content/js/jquery-ui-1.10.3.full.min.js")"></script>
    <script src="@Url.Content("~/Content/js/jquery-ui-1.10.3.custom.min.js")"></script>
    <script src="@Url.Content("~/Content/js/jquery.ui.touch-punch.min.js")"></script>
    <script src="@Url.Content("~/Content/js/jquery.slimscroll.min.js")"></script>
    <!-- ace scripts -->
    <script src="@Url.Content("~/Content/js/ace-elements.min.js")"></script>
    <script src="@Url.Content("~/Content/js/ace.min.js")"></script>
    <script>
        function showMask(pCtl) {
            var loading = $('#content-Loading');
            loading.offset(pCtl.offset());
            loading.width(pCtl.width());
            var h = pCtl.height();
            loading.height(h);
            var loadingText = loading.find('h4');
            loadingText.css('margin-top', (h / 2 - 30) + "px");
            loading.css('display', 'block');
        }

        function removeMask() {
            $('#content-Loading').css("display", "none");
        }

        var lastTarget = "SystemConfig/TUnit";
        $(function () {
            var fc = $('#frameContent');
            fc.height($(window).height() - fc.offset().top);
            showMask(fc);
            fc.on('load', function () {
                removeMask(fc);
            });
            $('.nav-list li a').on('click', function (e) {
                var obj = $(e.currentTarget);
                var objParent = obj.parent();
                var title = $('.main-content .breadcrumb li');
                var menuText = objParent.parents('li').find('.dropdown-toggle .menu-text')[0];
                if (menuText != null) {
                    title[1].innerText = menuText.innerText;
                    title[2].innerText = objParent[0].innerText;
                }
                if (obj.hasClass("dropdown-toggle")) {
                    var b = objParent.find('b');
                    b.removeClass();
                    if (objParent.hasClass("active")) {
                        objParent.removeClass("active");
                        b.addClass("arrow icon-angle-up");
                    }
                    else {
                        objParent.addClass('active');
                        b.addClass("arrow icon-angle-down");
                    }
                    return false;
                }
                var target = obj.attr('target');
                if (lastTarget == target)
                    return false;
                else
                    lastTarget = target;
                $('#content-Loading').css("display", "block");
                $('.nav-list li.active').each(function (i, o) {
                    if (!$(o.firstElementChild).hasClass("dropdown-toggle"))
                        $(o).removeClass('active');
                });
                objParent.addClass('active');
                $('#frameContent').attr('src', lastTarget);
                return false;
            });
            $('.nav-list li:eq(1)').addClass('active');
            $('#frameContent').attr('src', lastTarget);
        });

        $(function () {
            //override dialog's title function to allow for HTML titles
            $.widget("ui.dialog", $.extend({},
            $.ui.dialog.prototype, {
                _title: function (title) {
                    var $title = this.options.title || '&nbsp;'
                    if (("title_html" in this.options) && this.options.title_html == true)
                        title.html($title);
                    else
                        title.text($title);
                }
            }));
        });

        function modalOpen(opt) {
            var editor = $('#dialog-editor');
            var frame = editor.find("iframe");
            frame.contents().find("body").html("");
            frame.attr("src", opt.url);
            if (opt.width == null)
                opt.width = "700";
            if (opt.height == null)
                opt.height = "600";
            frame.height(opt.height - 95);
            var dlgOpt = {
                modal: true,
                width: opt.width,
                height: opt.height,
                title: "<div class='widget-header widget-header-small'><h4 class='smaller'><i class='icon-list-alt'></i>" + opt.title + "</h4></div>",
                title_html: true,
                buttons: [
                {
                    html: "<i class='icon-ok bigger-110'></i>&nbsp; 确定",
                    "class": "btn btn-primary btn-xs",
                    click: function () {
                        opt.callback();
                    }
                },
                {
                    html: "<i class='icon-remove bigger-110'></i>&nbsp; 取消",
                    "class": "btn btn-info btn-xs",
                    click: function () {
                        $(this).dialog("close");
                    }
                }]
            };
            if (opt.view)
                dlgOpt.buttons.splice(0, 1);
            editor.removeClass('hide').dialog(dlgOpt);
        }

        function modalClose() {
            $('#dialog-editor').dialog("close");
        }

        function modalConfirm(opt) {
            var dlgOpt = {
                modal: true,
                title: "<div class='widget-header widget-header-small'><h4 class='smaller'><i class='icon-warning-sign red'></i>" + opt.title + "</h4></div>",
                title_html: true,
                buttons: [
                {
                    html: "<i class='icon-ok bigger-110'></i>&nbsp; 是",
                    "class": "btn btn-primary btn-xs",
                    click: function () {
                        opt.callback();
                    }
                },
                {
                    html: "<i class='icon-remove bigger-110'></i>&nbsp; 否",
                    "class": "btn btn-info btn-xs",
                    click: function () {
                        $(this).dialog("close");
                    }
                }]
            };
            $('#dialog-confirm p').text(opt.text);
            $('#dialog-confirm').removeClass('hide').dialog(dlgOpt);
        }

        function modalConfirmClose() {
            $('#dialog-confirm').dialog("close");
        }
    </script>
</body>
</html>
